/**
 * Company : SIANGKLOM.
 * Created By : Chatree Siangklom
 * Created On : Aug 27, 2013  2:57:05 PM 
 * e-Mail : dr_chatree@hotmail.com
 * Mobile Phone : (+66) 087-921-5115
 * Package Name : com.tis.database.entitys.staging
 * File Name : SyncQueue.java
 * TODO
 */
package com.tis.database.entitys.queue;

import javax.persistence.Entity;

import java.io.Serializable;
import java.math.BigDecimal;

import javax.persistence.*;

import org.apache.commons.lang.builder.ToStringBuilder;

import com.tis.database.entitys.CommonEntity;

import promis.utility.CommonService;

import java.util.Date;

/**
 * The persistent class for the SYNC_QUEUE database table.
 * 
 */
@Entity
@Table(name="SYNC_QUEUE")
@NamedQueries({
    @NamedQuery(name = SyncQueue.findAll, query = "FROM SyncQueue c order by c.pkId asc"),
    @NamedQuery(name = SyncQueue.findById, query = "FROM SyncQueue c WHERE c.pkId = :pkId"),
    @NamedQuery(name = SyncQueue.findBySearch, query = "FROM SyncQueue c WHERE 1 = 1 ")
    })
public class SyncQueue extends CommonEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	public static final String findAll = "SyncQueue_findAll";
	public static final String findById = "SyncQueue_findById";
	public static final String findBySearch = "SyncQueue_findBySearch";
	
	@Override
	public String toString()
	{
		return ToStringBuilder.reflectionToString(this);
	}
	
	@Id
	@Column(name="QUEUE_ID")
	private Long pkId;
	
	
	public String getProcUpdatedonToString() {
		if(this.procCreatedon != null)
			return CommonService.ConvertDateTimeToStringDisplay(this.procCreatedon);
		else 
			return "";
	}
	
	public String getProcUpdatedonString() {
		if(this.procUpdatedon != null)
			return CommonService.ConvertDateTimeToStringDisplay(this.procUpdatedon);
		else 
			return "";
	}
	
	@Column(name="IS_ACTIVE")
	private String isActive;

	@Column(name="IS_PROCESSING")
	private String isProcessing;
	
	@Column(name="PROCESSING_NAME")
	private String processingName;
	
	@Column(name="PROC_CREATEDBY")
	private String procCreatedby;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name="PROC_CREATEDON")
	private Date procCreatedon;

	@Column(name="PROC_UPDATEDBY")
	private String procUpdatedby;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name="PROC_UPDATEDON")
	private Date procUpdatedon;

	@Column(name="PROCESS_CODE")
	private String processCode;

	@Column(name="PROCESS_DESC")
	private String processDesc;

	@Column(name="PROCESS_MODULE")
	private String processModule;

	@Column(name="PROCESS_PATH")
	private String processPath;
	
	@Column(name="PROCESS_ACTION")
	private String processAction;	

	@Column(name="QUEUE_SEQUENCE")
	private BigDecimal queueSequence;
	
	@Column(name="PROCESSING_COUNT")
	private Integer processingCount;

	@Column(name="PROCESS_LEVEL")
	private String processLevel;

	/**
	 * @return the pkId
	 */
	public Long getPkId() {
		return pkId;
	}

	/**
	 * @param pkId the pkId to set
	 */
	public void setPkId(Long pkId) {
		this.pkId = pkId;
	}

	/**
	 * @return the isActive
	 */
	public String getIsActive() {
		return isActive;
	}

	/**
	 * @param isActive the isActive to set
	 */
	public void setIsActive(String isActive) {
		this.isActive = isActive;
	}

	/**
	 * @return the isProcessing
	 */
	public String getIsProcessing() {
		return isProcessing;
	}

	/**
	 * @param isProcessing the isProcessing to set
	 */
	public void setIsProcessing(String isProcessing) {
		this.isProcessing = isProcessing;
	}

	/**
	 * @return the processingName
	 */
	public String getProcessingName() {
		return processingName;
	}

	/**
	 * @param processingName the processingName to set
	 */
	public void setProcessingName(String processingName) {
		this.processingName = processingName;
	}

	/**
	 * @return the procCreatedby
	 */
	public String getProcCreatedby() {
		return procCreatedby;
	}

	/**
	 * @param procCreatedby the procCreatedby to set
	 */
	public void setProcCreatedby(String procCreatedby) {
		this.procCreatedby = procCreatedby;
	}

	/**
	 * @return the procCreatedon
	 */
	public Date getProcCreatedon() {
		return procCreatedon;
	}

	/**
	 * @param procCreatedon the procCreatedon to set
	 */
	public void setProcCreatedon(Date procCreatedon) {
		this.procCreatedon = procCreatedon;
	}

	/**
	 * @return the procUpdatedby
	 */
	public String getProcUpdatedby() {
		return procUpdatedby;
	}

	/**
	 * @param procUpdatedby the procUpdatedby to set
	 */
	public void setProcUpdatedby(String procUpdatedby) {
		this.procUpdatedby = procUpdatedby;
	}

	/**
	 * @return the procUpdatedon
	 */
	public Date getProcUpdatedon() {
		return procUpdatedon;
	}

	/**
	 * @param procUpdatedon the procUpdatedon to set
	 */
	public void setProcUpdatedon(Date procUpdatedon) {
		this.procUpdatedon = procUpdatedon;
	}

	/**
	 * @return the processCode
	 */
	public String getProcessCode() {
		return processCode;
	}

	/**
	 * @param processCode the processCode to set
	 */
	public void setProcessCode(String processCode) {
		this.processCode = processCode;
	}

	/**
	 * @return the processDesc
	 */
	public String getProcessDesc() {
		return processDesc;
	}

	/**
	 * @param processDesc the processDesc to set
	 */
	public void setProcessDesc(String processDesc) {
		this.processDesc = processDesc;
	}

	/**
	 * @return the processModule
	 */
	public String getProcessModule() {
		return processModule;
	}

	/**
	 * @param processModule the processModule to set
	 */
	public void setProcessModule(String processModule) {
		this.processModule = processModule;
	}

	/**
	 * @return the processPath
	 */
	public String getProcessPath() {
		return processPath;
	}

	/**
	 * @param processPath the processPath to set
	 */
	public void setProcessPath(String processPath) {
		this.processPath = processPath;
	}

	/**
	 * @return the processAction
	 */
	public String getProcessAction() {
		return processAction;
	}

	/**
	 * @param processAction the processAction to set
	 */
	public void setProcessAction(String processAction) {
		this.processAction = processAction;
	}

	/**
	 * @return the queueSequence
	 */
	public BigDecimal getQueueSequence() {
		return queueSequence;
	}

	/**
	 * @param queueSequence the queueSequence to set
	 */
	public void setQueueSequence(BigDecimal queueSequence) {
		this.queueSequence = queueSequence;
	}

	/**
	 * @return the processingCount
	 */
	public Integer getProcessingCount() {
		return processingCount;
	}

	/**
	 * @param processingCount the processingCount to set
	 */
	public void setProcessingCount(Integer processingCount) {
		this.processingCount = processingCount;
	}

	/**
	 * @return the processLevel
	 */
	public String getProcessLevel() {
		return processLevel;
	}

	/**
	 * @param processLevel the processLevel to set
	 */
	public void setProcessLevel(String processLevel) {
		this.processLevel = processLevel;
	}
	
}